Add Queue.Job.* lifecycle events with optional Sentry bridge#453
Merged
dereuromark merged 1 commit intomasterfrom Jan 11, 2026
Merged
Add Queue.Job.* lifecycle events with optional Sentry bridge#453dereuromark merged 1 commit intomasterfrom
dereuromark merged 1 commit intomasterfrom
Conversation
Add generic events for queue job lifecycle: - Queue.Job.created: when job is added to queue - Queue.Job.started: when job processing starts - Queue.Job.completed: when job completes successfully - Queue.Job.failed: when job fails Add CakeSentryEventBridge listener that bridges these events to CakeSentry.Queue.* events for lordsimal/cakephp-sentry integration. Users can enable it with: EventManager::instance()->on(new CakeSentryEventBridge())
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #453 +/- ##
============================================
+ Coverage 73.28% 73.91% +0.63%
- Complexity 777 786 +9
============================================
Files 41 42 +1
Lines 2691 2760 +69
============================================
+ Hits 1972 2040 +68
- Misses 719 720 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This was referenced Dec 28, 2025
LordSimal
approved these changes
Jan 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds generic queue job lifecycle events with an optional bridge for Sentry integration. This is an alternative to PRs #449 and #452, providing a middle-ground approach.
Generic Events
The plugin now dispatches standard lifecycle events:
Queue.Job.created- when a job is added to the queueQueue.Job.started- when a worker begins processing a jobQueue.Job.completed- when a job finishes successfullyQueue.Job.failed- when a job fails (with exception data)These events are useful for any monitoring, logging, or external integration.
Optional Sentry Integration
For lordsimal/cakephp-sentry integration, users can register the included
CakeSentryEventBridge:This bridges the generic events to
CakeSentry.Queue.*events that the Sentry plugin listens to.Key Benefits
Related Issues
Test plan
Queue.Job.createdeventQueue.Job.startedeventQueue.Job.completedeventQueue.Job.failedeventCakeSentryEventBridgelistener